projects
/
ostree.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8eaaea7
)
ostree-prepare-root: Don't require an extraneous argument
author
Colin Walters
<walters@verbum.org>
Mon, 3 Jun 2013 02:18:19 +0000
(22:18 -0400)
committer
Colin Walters
<walters@verbum.org>
Mon, 3 Jun 2013 02:19:24 +0000
(22:19 -0400)
src/switchroot/ostree-prepare-root.c
patch
|
blob
|
history
diff --git
a/src/switchroot/ostree-prepare-root.c
b/src/switchroot/ostree-prepare-root.c
index 65bb73054a1a3a73df046d16f486ecbd1e52f34d..470ed3c7a932e91b5d1f3afd5465e86010b057ce 100644
(file)
--- a/
src/switchroot/ostree-prepare-root.c
+++ b/
src/switchroot/ostree-prepare-root.c
@@
-82,7
+82,7
@@
parse_ostree_cmdline (char **out_osname,
{
const char *next = strchr (iter, ' ');
const char *next_nonspc = next;
- while (*next_nonspc == ' ')
+ while (
next_nonspc &&
*next_nonspc == ' ')
next_nonspc += 1;
if (strncmp (iter, "ostree=", strlen ("ostree=")) == 0)
{
@@
-121,9
+121,9
@@
main(int argc, char *argv[])
size_t len;
int i;
- if (argc <
3
)
+ if (argc <
2
)
{
- fprintf (stderr, "usage: ostree-prepare-root SYSROOT
OSTREE
\n");
+ fprintf (stderr, "usage: ostree-prepare-root SYSROOT\n");
exit (1);
}